package com.community.feign.contents.category;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.community.common.core.utils.Result;
import com.community.feign.contents.dto.CategoryDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;


@Component
@FeignClient(name = "community-contents",path = "contents/category",contextId = "community-contents-category")
public interface CategoryFeign {

    @PostMapping
    public boolean save(@RequestBody CategoryDTO dto);

    @PostMapping("page")
    public Result<Page<CategoryDTO>> page(@RequestBody Page<CategoryDTO> params);


}
